﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data;

namespace Ewts.Trace
{
    public partial class BugTraceList : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!Page.IsPostBack)
            {
                bindTraceList();
            }
        }

        private void bindTraceList()
        {
            DataTable dt = new DataTable();
            dt = new DataLib.BLL.BugTraceTab().GetList("").Tables[0];
            rept.DataSource = dt;
            rept.DataBind();
        }

        /// <summary>
        /// 获取字符串
        /// </summary>
        /// <param name="str"></param>
        /// <returns></returns>
        public string GetSubString(string str, int len)
        {
            string strreturn = "";
            if (str.Length > len)
            {
                strreturn = str.Substring(0, len) + "...";
            }
            else
            {
                strreturn = str;
            }
            return strreturn;
        }
    }
}